// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.

import promise from 'es6-promise'
import 'whatwg-fetch'
import Vue from 'vue'
import Upload from 'element-ui/lib/upload'
import 'element-ui/lib/theme-default/index.css'
import App from './App'
import router from './router'
// import AlertPlugin from 'vux/src/plugins/alert'
// import ToastPlugin from 'vux/src/plugins/toast'
import AlertPlugin from 'vux/src/plugins/Alert'
import ToastPlugin from 'vux/src/plugins/Toast'
import imageUrl from './common/global.js'
import wx from 'weixin-js-sdk'

Vue.use(AlertPlugin)
Vue.use(ToastPlugin)
Vue.use(Upload)
promise.polyfill()
Vue.prototype.imageUrl = imageUrl
Vue.prototype.wx = wx
Vue.config.productionTip = false

/* eslint-disable no-new */
new Vue({
  el: '#app',
  router,
  template: '<App/>',
  components: { App }
})
